from header_factions import *

####################################################################################################################
#  Each faction record contains the following fields:
#  1) Faction id: used for referencing factions in other files.
#     The prefix fac_ is automatically added before each faction id.
#  2) Faction name.
#  3) Faction flags. See header_factions.py for a list of available flags
#  4) Faction coherence. Relation between members of this faction.
#  5) Relations. This is a list of relation records.
#     Each relation record is a tuple that contains the following fields:
#    5.1) Faction. Which other faction this relation is referring to
#    5.2) Value: Relation value between the two factions.
#         Values range between -1 and 1.
#  6) Ranks
#  7) Faction color (default is gray)
####################################################################################################################

default_kingdom_relations = [("outlaws",-0.05),("peasant_rebels", -0.1),("deserters", -0.02),("mountain_bandits", -0.02),("forest_bandits", -0.02)]
factions = [
  ("player_faction","Player Faction",0, 0.9, [], []),
  ("commoners","Commoners",0, 0.1,[("player_faction",0.1)], []),
  ("outlaws","Outlaws", max_player_rating(-30), 0.5,[("commoners",-0.6),("player_faction",-0.05)], []),
# Factions before this point are hardwired into the game end their order should not be changed.
  # ('quest_bandits','Outlaws',0,1.0,[('player_faction',-1.0)],[],
  ("neutral","neutral",0, 0.1,[("player_faction",0.0)]),
  ("innocents","innocents", 0, 0.5,[("outlaws",-0.05)]),
  ("imperial","imperial", 0, 0.9,[("hosokawa",0.3),("yamana",0.1)]),
  ("tendai_sect","tendai_sect", 0, 0.9,[("jodo_shinsu_sect",-0.5),("rinzai_sect",-0.5),
                          ("hosokawa",0.1),("hosokawa_kuge",0.05),
						  #("hosokawa_peasants",0.25),
                          ("yamana",-0.1),("yamana_kuge",-0.25),
						  #("yamana_peasants",-0.05),
						  ]),
  ("jodo_shinsu_sect","jodo_shinsu_sect", 0, 0.9,[("tendai_sect",-0.5),("rinzai_sect",-0.5),
                          ("hosokawa",-0.1),("hosokawa_kuge",-0.25),
						  #("hosokawa_peasants",-0.05),
                          ("yamana",0.1),("yamana_kuge",0.05),
						  #("yamana_peasants",0.25),
						  ]),
  ("rinzai_sect","rinzai_sect", 0, 0.9,[("jodo_shinsu_sect",-0.5),("tendai_sect",-0.5),
                          ("hosokawa",-0.1),("hosokawa_kuge",-0.25),
						  #("hosokawa_peasants",0.05),
                          ("yamana",-0.1),("yamana_kuge",-0.25),
						  #("yamana_peasants",0.05),
						  ]),
  ("koga","koga", 0, 0.9,[("commoners",0.9)]),
  ("iga","iga", 0, 0.9,[("commoners",0.9)]),
  ("samurai","samurai", 0, 0.3,[("outlaws",-0.6)]),
  ("ronin","ronin", 0, 0.1,[("player_faction",0.1)]),
  ("ikko_ikki","ikko_ikki",0, 0.4, [("hosokawa",-0.25),("yamana",-0.25),("tendai_sect",-0.50)]),
  ("merchants","merchants", 0, 0.3,[]),
  ('quest_bandits','quest_bandits',0,0.5,[('player_faction',-1.0)]),
  ('ginza','Gin-za',0,0.25,[('enza',-0.25),('andaza',-0.25),('outlaws',-1.0)]),
  ('enza','En-za',0,0.25,[('ginza',-0.25),('andaza',-0.25),('outlaws',-1.0)]),
  ('andaza','Anda-za',0,0.25,[('enza',-0.25),('ginza',-0.25),('outlaws',-1.0)]),
  ("hosokawa","Hosokawa", 0, 0.5,[("imperial",0.3),("yamana",-0.6),("yamana_kuge",-0.1),
								  #("yamana_peasants",-0.3),
                                  ("outlaws",-0.6),("ishikki",-0.2),("yamana_hatakeyama",-0.2),("rokkaku",-0.2),
                                  ("toki",-0.2),("shiba",-0.2),("akamatsu",0.2),("hosokawa_hatakeyama",0.2),
                                  ("takeda",0.2),("kyogoku",0.1),]),
  ("hosokawa_kuge","Hosokawa_kuge", 0, 0.5,[("hosokawa",0.6),("imperial",0.3),("yamana",-0.2)]),
  #("hosokawa_peasants","hosokawa_peasants", 0, 0.5,[("hosokawa",0.6),("imperial",0.3),("yamana",-0.2)]),
  ("akamatsu","Akamatsu", 0, 0.5,[("hosokawa",0.2),("hosokawa_kuge",0.2),("hosokawa_hatakeyama",0.1),("takeda",0.1),("kyogoku",0.1),
                                  ("yamana",-0.2),("yamana_kuge",-0.2),("ishikki",-0.1),("yamana_hatakeyama",-0.1),
                                  ("rokkaku",-0.1),("toki",-0.1),("shiba",-0.1),]),
  ("hosokawa_hatakeyama","Hosokawa-Hatakeyama", 0, 0.5,[("hosokawa",0.2),("hosokawa_kuge",0.2),
                                                        ("akamatsu",0.1),("takeda",0.1),("takeda",0.1),("yamana",-0.2),
                                                        ("yamana_kuge",-0.2),("ishikki",-0.1),("yamana_hatakeyama",-0.1),
                                                        ("rokkaku",-0.1),("toki",-0.1),("shiba",-0.1),]),
  ("takeda","Takeda", 0, 0.5,[("hosokawa",0.2),("hosokawa_kuge",0.2),("hosokawa_hatakeyama",0.1),("akamatsu",0.1),("kyogoku",0.1),
                                  ("yamana",-0.2),("yamana_kuge",-0.2),("ishikki",-0.1),("yamana_hatakeyama",-0.1),
                                  ("rokkaku",-0.1),("toki",-0.1),("shiba",-0.1),]),
  ("kyogoku","Kyogoku", 0, 0.5,[("hosokawa",0.2),("hosokawa_kuge",0.2),("hosokawa_hatakeyama",0.1),("akamatsu",0.1),("kyogoku",0.1),
                                  ("yamana",-0.2),("yamana_kuge",-0.2),("ishikki",-0.1),("yamana_hatakeyama",-0.1),
                                  ("rokkaku",-0.3),("toki",-0.1),("shiba",-0.1),]),
  ("yamana","Yamana", 0, 0.5,[("imperial",0.1),("hosokawa",-0.6),("hosokawa_kuge",-0.1),
							  #("yamana_peasants",-0.3),
                              ("outlaws",-0.6),("akamatsu",-0.2),("hosokawa_hatakeyama",-0.2),("takeda",-0.2),
                              ("ishikki",0.2),("yamana_hatakeyama",0.2),("rokkaku",0.2),("toki",0.2),
                              ("shiba",0.2),("kyogoku",-0.1),]),
  ("yamana_kuge","Yamana_kuge", 0, 0.5,[("yamana",0.6),("imperial",0.1),("hosokawa",-0.2)]),
  #("yamana_peasants","yamana_peasants", 0, 0.5,[("yamana",0.6),("imperial",0.1),("hosokawa",-0.2)]),
  ("ishikki","Ishikki", 0, 0.5,[("yamana",0.2),("yamana_kuge",0.2),("yamana_hatakeyama",0.1),("rokkaku",0.1),
                                ("toki",0.1),("shiba",0.1),("hosokawa",-0.2),("hosokawa_kuge",-0.2),("akamatsu",-0.1),
                                ("hosokawa_hatakeyama",-0.1),("takeda",-0.1),("kyogoku",-0.1),]),
  ("yamana_hatakeyama","Yamana-Hatakeyama", 0, 0.5,[("yamana",0.2),("yamana_kuge",0.2),("ishikki",0.1),("rokkaku",0.1),
                                ("toki",0.1),("shiba",0.1),("hosokawa",-0.2),("hosokawa_kuge",-0.2),("akamatsu",-0.1),
                                ("hosokawa_hatakeyama",-0.1),("takeda",-0.1),("kyogoku",-0.1),]),
  ("rokkaku","Rokkaku", 0, 0.5,[("yamana",0.2),("yamana_kuge",0.2),("yamana_hatakeyama",0.1),("ishikki",0.1),
                                ("toki",0.1),("shiba",0.1),("hosokawa",-0.2),("hosokawa_kuge",-0.2),("akamatsu",-0.1),
                                ("hosokawa_hatakeyama",-0.1),("takeda",-0.1),("kyogoku",-0.3),]),
  ("toki","Toki", 0, 0.5,[("yamana",0.2),("yamana_kuge",0.2),("yamana_hatakeyama",0.1),("rokkaku",0.1),
                                ("ishikki",0.1),("shiba",0.1),("hosokawa",-0.2),("hosokawa_kuge",-0.2),("akamatsu",-0.1),
                                ("hosokawa_hatakeyama",-0.1),("takeda",-0.1),("kyogoku",-0.1),]),
  ("shiba","Shiba", 0, 0.5,[("yamana",0.2),("yamana_kuge",0.2),("yamana_hatakeyama",0.1),("rokkaku",0.1),
                                ("toki",0.1),("ishikki",0.1),("hosokawa",-0.2),("hosokawa_kuge",-0.2),("akamatsu",-0.1),
                                ("hosokawa_hatakeyama",-0.1),("takeda",-0.1),("kyogoku",-0.1),]),
  ("end_fac","end_fac",0,0,[]),
  ("end_factions","end_fac",0,0,[]),
]
